
//const
var MODEL_FILES =
[
    "",
    [
        "./3d/models/robot0.dae",
        "./3d/models/robot1.dae",
        "./3d/models/robot2.dae"
    ],
    "./3d/models/kitty.dae",
    "./3d/models/stone.dae",
    "./3d/models/monster.dae",
    "./3d/models/ball.dae",
    [
        "./3d/models/door0.dae",
        "./3d/models/door1.dae",
        "./3d/models/door2.dae",
        "./3d/models/door3.dae"
    ],
    [
        "./3d/models/key0.dae",
        "./3d/models/key1.dae",
        "./3d/models/key2.dae",
        "./3d/models/key3.dae"
    ],
    [
        "./3d/models/skill0.dae",
        "./3d/models/skill1.dae",
        "./3d/models/skill2.dae",
        "./3d/models/skill3.dae"
    ]
]

var ANIM_TIME = 1000;
var ANIM_FRAME_TIME = 20;

var SHOOT_TIME = 100;
var SHOOT_MIN = 1;
var SHOOT_MAX = 8;

var JUMP_HEIGHT = 15; 
var JUMP_STEP = 0.2;
var WALK_STEP = 0.1;
var Z_LOWER_BOUND = -2;
var G = 0.2;
var FULL_WIDTH = 900;
var FULL_HEIGHT = 400;
var SINGLE_WIDTH = 450;
var SINGLE_HEIGHT = 400;
var ROBOT_FORE = new THREE.Vector3(0, -1, 0);            

//graphics

var stats;
var camera, scene, renderer;
var cameras = [];
var player_num = 1;
var stage = 0;
var player_cnt = 0;
var key_cnt = 0;
var door_cnt = 0;
var skill_cnt = 0;
var cam_rel_vecs = [];

var dae_cnt = 0;
var dae_loaded = 0;

//global vars
var objs = new Array(10);
for (var i=0; i<10; ++i){
    objs[i] = [];
}

var rob_ori_pos = [];
var rob_ori_rot = [];

var anim_handler;

//symbol links
var robots = objs[ObjType.ROBOT];
var kittys = objs[ObjType.KITTY];
var stones = objs[ObjType.STONE];
var monsters = objs[ObjType.MONSTER];
var balls = objs[ObjType.BALL];
var doors = objs[ObjType.DOOR];
var keys = objs[ObjType.KEY];
var skills = objs[ObjType.SKILL];
//tmp vars
var robot, kitty, stone, monster, ball, door, key, skill;
